package com.sims.action.teacher;

import org.springframework.beans.factory.annotation.Autowired;

import com.sims.bean.Teacher;
import com.sims.service.TeacherService;
import com.sims.util.ActionEnhanced;
import com.sims.util.Constant;

public class ModifyTeacherPasswordAction extends ActionEnhanced{
	private Teacher teacher;
	@Autowired
	private TeacherService teacherService;
	public Teacher getTeacher() {
		return teacher;
	}
	public void setTeacher(Teacher teacher) {
		this.teacher = teacher;
	}
	@Override
	public String execute() {
		
		result = teacherService.modifyTeacherPassword(teacher);
		if (result.containsKey(Constant.SUCCESS)) {
			System.out.println("success");
			return SUCCESS;
		}
		return ERROR;
	}
}
